package com.k7k7.cserver.sceneclient;

import org.apache.log4j.Logger;

import java.io.BufferedReader;
import java.io.IOException;
import java.net.ServerSocket;
import java.net.Socket;

/**
 * Created by IntelliJ IDEA.
 * User: Administrator
 * Date: 2009-4-21
 * Time: 18:01:42
 */
public class SceneServerThread extends Thread {
	private ServerSocket socket;
	private BufferedReader reader;
	private Logger log=Logger.getLogger(SceneServerThread.class);

	public SceneServerThread(Integer port) throws IOException {
		this.socket = new ServerSocket(port);
	}

	@Override
	public void run() {
		try {
			Socket socket = this.socket.accept();
			SceneServerClient u = new SceneServerClient(socket);
			u.start();
		} catch (Exception e) {
			log.error("新建场景服务错误");
		}
	}
}
